package cn.tiancaifan.micro.controller;


import cn.tiancaifan.micro.entity.Menu;
import cn.tiancaifan.micro.mapper.MenuMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
public class HelloController {

    @Autowired
    MenuMapper menuMapper;

    @RequestMapping("/hello")
    public String Hello(){
        return "hello";
    }

    @RequestMapping("/test")
    public List<Menu> test(){
        return menuMapper.getMenusByHrId(3);
    }

    @RequestMapping("/employee/basic/hello")
    public String hello(){
        return "/employee/basic/hello";
    }

    @RequestMapping("/employee/advanced/hello")
    public String hello2(){
        return "/employee/advanced/hello";
    }
}
